#include "precompiled.h"
#include "Lexer.h"
#include "FileReader.h"
#include "IMLGenerator.h"

using namespace IcyCrystal;


int main() {
	FileReader reader;
	reader.readFile("C:/lisp/file.txt");

	Lexer lex(reader);

	Parser parse(lex);

	try {
		parse.generateSyntaxTree();
		IMLGenerator gen( parse.getGlobalNamespace(), parse.getSyntaxTree());
		gen.generateIML();
	}
	catch( ParserException e ){
		cout << "\nException: " << e.what() << endl;
	}

	

	getchar();
		
}